
import javax.microedition.lcdui.*;

class StartApp extends Canvas{
  private Image image;
  private String welcome;

  public StartApp(){
      setFullScreenMode(true);
      welcome = new String("Welcome to KIWI social network!");
    try{
      image = Image.createImage("/logo.png");
   
     
    }
    catch (Exception e){
        throw new RuntimeException("Loi tai hinh anh: "+e);
    }
  }

  
  protected void paint(Graphics g){
    g.setColor(0xffffff);
    g.fillRect(0, 0, getWidth(), getHeight());
  
    g.drawImage(image, getWidth() / 2, getHeight() / 2, Graphics.HCENTER | Graphics.VCENTER);
    Font f = Font.getFont(Font.FACE_SYSTEM, Font.STYLE_PLAIN, Font.SIZE_SMALL);
    g.setColor(0xff0000);
    g.setFont(f);
    g.drawString(welcome, getWidth()/2, 5, Graphics.TOP | Graphics.HCENTER);
   
    }
  }
